<cfcomponent>
	<cffunction name="getMasterQuery" output="false" access="remote" returntype="query">
		<cfargument name="ID" required="false">
		<cfset var qRead="">

		<cfquery name="qRead" datasource="BRUST">
SELECT    Medicao.medicaoId, Instituicao.nome, Equipamento.rotulo, convert(varchar,Medicao.dataCadastro,103) dataCadastro, Medicao.tecnicoCadastro
FROM      dbo.Medicao, dbo.Equipamento, dbo.Instituicao 
WHERE     dbo.Medicao.equipamentoId = dbo.Equipamento.equipamentoId
  AND     dbo.Equipamento.institucaoId = dbo.Instituicao.institucaoId
		</cfquery>

		<cfreturn qRead>
	</cffunction>

	<cffunction name="deleteItem" output="false" access="remote" returntype="void">
		<cfargument name="ID" required="true">

		<cfscript>
			MedicaoGateway = createObject("component", "slr.components.cfgenerated.Medicao_Detail.MedicaoGateway");
			MedicaoGateway.deleteByID(arguments.ID);
		</cfscript>
	</cffunction>
</cfcomponent>
